﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Register.aspx.cs" Inherits="AiXiu.WebSite.Register" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <title>注册</title>
    <link href="Content/mui/css/mui.min.css" rel="stylesheet" />
    <link href="Content/mui/css/app.css" rel="stylesheet" />
    <link href="Content/reg.css" rel="stylesheet" />
</head>
<body>
    <div class="mui-content">
        <form id="form" runat="server" class="mui-input-group">
            <img src="imgs/account-bg.jpg" />
            <div class="mui-input-row">
                <label>用户名</label>
                <asp:TextBox ID="txtUserName" runat="server" class="mui-input-clear mui-input" placeholder="请输入用户名"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="用户名不能为空" ControlToValidate="txtUserName"></asp:RequiredFieldValidator>
            </div>
            <div class="mui-input-row">
                <label>手机号</label>
                <asp:TextBox ID="txtPhoneNumber" runat="server" class="mui-input-clear mui-input" placeholder="请输入手机号" TextMode="Number"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="手机号不能为空" ControlToValidate="txtPhoneNumber"></asp:RequiredFieldValidator>
                <asp:RegularExpressionValidator ID="RegularExpressionValidator1" ControlToValidate="txtPhoneNumber" runat="server" ErrorMessage="手机号格式有误" ValidationExpression="^1[0-9]{10}$"></asp:RegularExpressionValidator>
            </div>
            <div class="mui-input-row">
                <label>密码</label>
                <asp:TextBox ID="txtPassword" runat="server" class="mui-input-clear mui-input" placeholder="请输入密码" TextMode="Password"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ErrorMessage="密码不能为空" ControlToValidate="txtPassword"></asp:RequiredFieldValidator>
            </div>
            <div class="mui-input-row">
                <label>验证码</label>
                <asp:TextBox ID="txtCode" runat="server" class="mui-input-clear mui-input" placeholder="请输入验证码"></asp:TextBox>
                <img src="Handler/CaptchaHandler.ashx" class="captcha" />
                <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ErrorMessage="验证码不能为空" ControlToValidate="txtCode"></asp:RequiredFieldValidator>
            </div>

            <div class="mui-content-padded">
                <asp:Button ID="reg" runat="server" Text="注册" class="mui-btn mui-btn-block"  />

            </div>
            <div class="mui-content-padded">
                <div class="link-area">
                    <span class="spliter">已有账号？ </span>
                    <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/Login.aspx">现在登录</asp:HyperLink>


                </div>

            </div>
        </form>

    </div>
    <script src="scripts/jquery-1.8.3.min.js"></script>
    <script>
        // 图形验证码点击刷新
        var captcha = $('.captcha');
        var captchaSrc = captcha.attr('src')
        captcha.on('click', function () {
            $(this).attr('src', captchaSrc + '?r=' + Math.random());
        })
    </script>
</body>
</html>
